import java.util.Scanner;

/**
 * Created with IntelliJ IDEA.
 * Description:
 * User: xiaotutu
 * Date: 2023-11-02
 * Time: 10:03
 */

/*class Shape {
    //属性....
    public void draw() {
        System.out.println("画图形！");
    }
}
class Rect extends Shape{
    @Override
    public void draw() {
        System.out.println("♦");
    }
}
class Cycle extends Shape{
    @Override
    public void draw() {
        System.out.println("●");
    }
}

class Flower extends Shape{
    @Override
    public void draw() {
        System.out.println("❀");
    }
}*/

    /*public static void drawShapes() {
        Rect rect = new Rect();
        Cycle cycle = new Cycle();
        Flower flower = new Flower();
        String[] shapes = {"cycle", "rect", "cycle", "rect", "flower"};
        for (String shape : shapes) {
            if (shape.equals("cycle")) {
                cycle.draw();
            } else if (shape.equals("rect")) {
                rect.draw();
            } else if (shape.equals("flower")) {
                flower.draw();
            }
        }
    }*/


/*    public static void drawShapes() {
// 我们创建了一个 Shape 对象的数组.
        Shape[] shapes = {new Cycle(), new Rect(), new Cycle(),
                new Rect(), new Flower()};
        for (Shape shape : shapes) {
            shape.draw();
        }
    */ //}

/*class Triangle extends Shape {
    @Override
    public void draw() {
        System.out.println("△");
    }
}*/

/*class B {
    public B() {
// do nothing
        func();
    }
    public void func() {
        System.out.println("B.func()");
    }
}
class D extends B {
    private int num = 1;
    @Override
    public void func() {
        System.out.println("D.func() " + num);
    }
}
public class Test {
    public static void main(String[] args) {
        D d = new D();
    }
}
*/

/*class Animal {
    public String name;
    public int age;

    public void eat() {
        System.out.println(this.name + "正在吃饭!");
    }
}

class Dog extends Animal{
    @Override
    public void eat() {
        System.out.println(this.name + "正在吃狗粮!");
    }
}

class Cat extends Animal{
    @Override
    public void eat() {
        System.out.println(this.name + "正在吃猫粮!");
    }
}*/

class Shape {
    //属性....
    public void draw() {
        System.out.println("画图形！");
    }
}
class Rect extends Shape{
    @Override
    public void draw() {
        System.out.println("♦");
    }
}
class Cycle extends Shape{
    @Override
    public void draw() {
        System.out.println("●");
    }
}

class Flower extends Shape{
    @Override
    public void draw() {
        System.out.println("❀");
    }
}

class Triangle extends Shape {
    @Override
    public void draw() {
        System.out.println("△");
    }
}

class Person {
    private int age;

    public int getAge() {
        if(this.age < 0) {
            return 0;
        }else if(this.age > 200) {
            return 200;
        }else{
            return this.age;
        }
    }

    public void setAge(int age) {
        this.age = age;
    }
}

class Base {
    private int x;
    private int y;

    public Base(int x, int y) {
        this.x = x;
        this.y = y;
    }

    public int getX() {
        return x;
    }

    public int getY() {
        return y;
    }
    public void calculate() {
        System.out.println(getX() * getY());
    }

    public final int sum() {
        return getX() + getY();
    }

}

class Sub extends Base{
    public Sub(int x, int y) {
        super(x, y);
    }

    public int getX() {
        return super.getX()*10;
    }


   /* @Override
    public void calculate() {
        if(super.getY() == 0) {
            System.out.println("Error");
            return;
        }
        System.out.println(this.getX() / this.getY());
    }*/
}

public class Test {

    public static void main(String[] args) {
        // Person p = new Person();
        Scanner scanner = new Scanner(System.in);
        while(scanner.hasNextInt()) {
            int x = scanner.nextInt();
            int y = scanner.nextInt();
            Sub sub = new Sub(x, y);
            System.out.println(sub.sum());
            // sub.calculate();

        }
    }



    public static void drawShapes1() {
        Rect rect = new Rect();
        Cycle cycle = new Cycle();
        Flower flower = new Flower();
        String[] shapes = {"cycle", "rect", "cycle", "rect", "flower"};
        for (String shape : shapes) {
            if (shape.equals("cycle")) {
                cycle.draw();
            } else if (shape.equals("rect")) {
                rect.draw();
            } else if (shape.equals("flower")) {
                flower.draw();
            }
        }
    }
    public static void drawShapes() {
        Shape[] shapes = {new Cycle(), new Rect(), new Cycle(), new Rect(), new Flower(), new Triangle()};
        for(Shape shape:shapes) {
            shape.draw();
        }
    }


    public static void main2(String[] args) {
        /*Shape shape = new Cycle();
        shape.draw();*/
        drawShapes();
    }

    public static void main1(String[] args) {
        /*Cat cat = new Cat();
        Dog dog = new Dog();
        Animal animal = cat;
        animal.eat();
        animal = dog;
        animal.eat();

        if(animal instanceof Cat) {
            animal = (Cat)animal;
            cat.eat();
        }*/

        /*if(animal instanceof Dog) {
            animal = (Dog)animal;
            dog.eat();
        }*/


    }
}
